#include <iostream>

//https://leetcode.cn/problems/first-unique-character-in-a-string/

using namespace std;

class Solution {
public:
    int firstUniqChar(string s) {
        int count[26] = {0};
        for (int i = 0; s[i] != '\0'; ++i) {
            count[s[i] - 'a']++;
        }
        for (int i = 0; s[i] != '\0'; ++i) {
            if (count[s[i] - 'a'] == 1) {
                return i;
            }
        }
        return -1;
    }
};

int main() {


    return 0;
}


